<?php
/**
 * A simple description for this script
 *
 * PHP Version 5.2.0 or Upper version
 *
 * @package    Paylog
 * @author     Hidehito NOZAWA aka Suin <http://suin.asia>
 * @copyright  2010 Hidehito NOZAWA
 * @license    http://www.gnu.org/licenses/gpl-2.0.html GNU GPL v2
 *
 */

abstract class Paylog_Abstract_AdminController extends Paylog_Abstract_Controller
{
	public function __construct()
	{
		if ( !defined('PAYLOG_ADMIN_MODE') )
		{
			die('error');
		}

		parent::__construct();
	}

	protected function _view()
	{
		if ( !$this->template )
		{
			$this->template = Paylog::$dirname.'.admin_'.Paylog::$_controller.'.'.Paylog::$_action.'.tpl';
		}

		require_once XOOPS_ROOT_PATH.'/class/template.php';
		require_once XOOPS_ROOT_PATH.'/include/cp_functions.php';

		$xoopsTpl = new XoopsTpl();

		xoops_cp_header();

		$this->_escapeHtml($this->output);
		$xoopsTpl->assign('paylog', $this->output);
		$xoopsTpl->display('db:'.$this->template);

		xoops_cp_footer();
	}
}

?>
